package ac.zlf.core.util;

public class Server {
    private int id;
    private String address;
    private Integer port;
    private ServerType type;
    private String webContext;
    private boolean https;

    public Server() {
    }

    public Server(int id, String address, Integer port, ServerType type, String webContext, boolean https) {
        this.id = id;
        this.address = address;
        this.port = port;
        this.type = type;
        this.webContext = webContext;
        this.https = https;
    }

    public int getId() {
        return this.id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getAddress() {
        return this.address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public Integer getPort() {
        return this.port;
    }

    public void setPort(Integer port) {
        this.port = port;
    }

    public ServerType getType() {
        return this.type;
    }

    public void setType(ServerType type) {
        this.type = type;
    }

    public String getWebContext() {
        return this.webContext;
    }

    public void setWebContext(String webContext) {
        this.webContext = webContext;
    }

    public boolean isHttps() {
        return this.https;
    }

    public void setHttps(boolean https) {
        this.https = https;
    }

    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("Server{");
        sb.append("id='" + this.id + "'");
        sb.append(", address='" + this.address + "'");
        if (this.port != null) {
            sb.append(", port=" + this.port);
        }
        sb.append(", type=" + this.type);
        sb.append(", webContext='" + this.webContext + "'");
        sb.append(", https=" + this.https);
        sb.append("}");
        return sb.toString();
    }
}